﻿Imports Microsoft.VisualBasic

Public Class DBPaymentOrderHdrSP
    Inherits DBParentStoredProcedureClass

    Public Operation As New TableField("Operation", Data.SqlDbType.NVarChar)
    Public PayOrdID As New TableField("PayOrdID", Data.SqlDbType.Int)
    Public PayOrderNo As New TableField("PayOrderNo", Data.SqlDbType.NVarChar)
    Public TransYear As New TableField("TransYear", Data.SqlDbType.Int)
    Public PayOrdDate As New TableField("PayOrdDate", Data.SqlDbType.DateTime)
    Public PayType As New TableField("PayType", Data.SqlDbType.Int)
    Public MainCostCenter As New TableField("MainCostCenter", Data.SqlDbType.Int)
    Public CostCenter As New TableField("CostCenter", Data.SqlDbType.Int)
    Public PayMeth As New TableField("PayMeth", Data.SqlDbType.Int)
    Public SupplierID As New TableField("SupplierID", Data.SqlDbType.Int)
    Public Remarks As New TableField("Remarks", Data.SqlDbType.NVarChar)
    Public RecordStatus As New TableField("RecordStatus", Data.SqlDbType.Int)
    Public LastUpdateBy As New TableField("LastUpdateBy", Data.SqlDbType.NVarChar)
    Public LastUpdateDate As New TableField("LastUpdateDate", Data.SqlDbType.DateTime)

    Sub New()
        MyBase.StoredProcedureName = "PaymentOrderHdrSP"
    End Sub

    Public Shadows Function QueryDatabase(ByVal QueryType As SqlQueryType, _
                                 Optional ByVal Operation As String = "", _
                                 Optional ByVal PayOrdID As String = "", _
                                 Optional ByVal PayOrderNo As String = "", _
                                 Optional ByVal TransYear As String = "", _
                                  Optional ByVal PayOrdDate As String = "", _
                                  Optional ByVal PayType As String = "", _
                                  Optional ByVal MainCostCenter As String = "", _
                                  Optional ByVal CostCenter As String = "", _
                                  Optional ByVal PayMeth As String = "", _
                                  Optional ByVal SupplierID As String = "", _
                                   Optional ByVal Remarks As String = "", _
                                  Optional ByVal RecordStatus As String = "", _
                                  Optional ByVal LastUpdateBy As String = "", _
                                  Optional ByVal LastUpdateDate As String = "") As Object

        MyBase.FieldsArrayList = New ArrayList
        Me.Operation.SetValue(Operation, MyBase.FieldsArrayList)
        Me.PayOrdID.SetValue(PayOrdID, MyBase.FieldsArrayList)
        Me.PayOrderNo.SetValue(PayOrderNo, MyBase.FieldsArrayList)
        Me.TransYear.SetValue(TransYear, MyBase.FieldsArrayList)
        Me.PayOrdDate.SetValue(PayOrdDate, MyBase.FieldsArrayList)
        Me.PayType.SetValue(PayType, MyBase.FieldsArrayList)
        Me.MainCostCenter.SetValue(MainCostCenter, MyBase.FieldsArrayList)
        Me.CostCenter.SetValue(CostCenter, MyBase.FieldsArrayList)
        Me.PayMeth.SetValue(PayMeth, MyBase.FieldsArrayList)
        Me.SupplierID.SetValue(SupplierID, MyBase.FieldsArrayList)
        Me.Remarks.SetValue(Remarks, MyBase.FieldsArrayList)
        Me.RecordStatus.SetValue(RecordStatus, MyBase.FieldsArrayList)
        Me.LastUpdateBy.SetValue(LastUpdateBy, MyBase.FieldsArrayList)
        Me.LastUpdateDate.SetValue(LastUpdateDate, MyBase.FieldsArrayList)

        Return MyBase.QueryDatabase(QueryType)
    End Function

End Class
